package cbfg.common.webview;

import android.content.Intent;
import android.graphics.Bitmap;
import android.net.Uri;
import android.net.http.SslError;
import android.view.KeyEvent;
import android.webkit.ConsoleMessage;
import android.webkit.PermissionRequest;
import android.webkit.SslErrorHandler;
import android.webkit.ValueCallback;
import android.webkit.WebChromeClient;
import android.webkit.WebResourceError;
import android.webkit.WebResourceRequest;
import android.webkit.WebResourceResponse;
import android.webkit.WebView;

/**
 * @Description: 类作用描述
 * @Author: TomHawk
 * @CreateDate: 5/29/2024 3:47 PM
 * @UpdateUser: TomHawk
 * @UpdateDate: 5/29/2024 3:47 PM
 * @UpdateRemark:
 */
public class SimpleWebHook implements WebHook {
    @Override
    public boolean shouldOverrideUrlLoading(WebView webView, String url) {
        return false;
    }

    @Override
    public void onPageFinished(WebView webView, String url) {
    }

    @Override
    public void onReceivedTitle(WebView webView, String title) {

    }

    @Override
    public void onProgressChanged(WebView webView, int newProgress) {
    }

    @Override
    public void onPageStarted(WebView webView, String url, Bitmap favicon) {
    }

    @Override
    public boolean onShowFileChooser(WebView webView, ValueCallback<Uri[]> filePathCallback, WebChromeClient.FileChooserParams fileChooserParams) {
        return false;
    }

    @Override
    public boolean onActivityResult(int requestCode, int resultCode, Intent intent) {
        return false;
    }

    @Override
    public void onReceivedError(WebView webView, WebResourceRequest request, WebResourceError error) {
    }

    @Override
    public WebResourceResponse shouldInterceptRequest(WebView view, WebResourceRequest request) {
        return null;
    }

    @Override
    public boolean onBackPressed() {
        return false;
    }

    @Override
    public boolean onKeyUp(int keyCode, KeyEvent event) {
        return false;
    }

    @Override
    public void onConsoleMessage(ConsoleMessage consoleMessage) {
    }

    @Override
    public void onReceivedSslError(WebView view, SslErrorHandler handler, SslError error) {
    }

    @Override
    public void onReceivedError(WebView webView, String url, int errorCode, String description) {
    }

    @Override
    public void onPermissionRequest(PermissionRequest request) {
    }
}
